<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<title>BuiltinFormats (POI API Documentation)</title>
<link rel="stylesheet" type="text/css" href="../../../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
    if (location.href.indexOf('is-external=true') == -1) {
        parent.document.title="BuiltinFormats (POI API Documentation)";
    }
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!--   -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/BuiltinFormats.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../../org/apache/poi/ss/usermodel/BorderStyle.html" title="enum in org.apache.poi.ss.usermodel"><span class="strong">PREV CLASS</span></a></li>
<li><a href="../../../../../org/apache/poi/ss/usermodel/Cell.html" title="interface in org.apache.poi.ss.usermodel"><span class="strong">NEXT CLASS</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?org/apache/poi/ss/usermodel/BuiltinFormats.html" target="_top">FRAMES</a></li>
<li><a href="BuiltinFormats.html" target="_top">NO FRAMES</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_top");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>SUMMARY:&nbsp;</li>
<li>NESTED&nbsp;|&nbsp;</li>
<li><a href="#field_summary">FIELD</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">CONSTR</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">METHOD</a></li>
</ul>
<ul class="subNavList">
<li>DETAIL:&nbsp;</li>
<li><a href="#field_detail">FIELD</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">CONSTR</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">METHOD</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!--   -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<p class="subTitle">org.apache.poi.ss.usermodel</p>
<h2 title="Class BuiltinFormats" class="title">Class BuiltinFormats</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li>java.lang.Object</li>
<li>
<ul class="inheritance">
<li>org.apache.poi.ss.usermodel.BuiltinFormats</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre>public final class <strong>BuiltinFormats</strong>
extends java.lang.Object</pre>
<div class="block">Utility to identify built-in formats.  The following is a list of the formats as
 returned by this class.<p/>
<p/>
       0, "General"<br/>
       1, "0"<br/>
       2, "0.00"<br/>
       3, "#,##0"<br/>
       4, "#,##0.00"<br/>
       5, "$#,##0_);($#,##0)"<br/>
       6, "$#,##0_);[Red]($#,##0)"<br/>
       7, "$#,##0.00);($#,##0.00)"<br/>
       8, "$#,##0.00_);[Red]($#,##0.00)"<br/>
       9, "0%"<br/>
       0xa, "0.00%"<br/>
       0xb, "0.00E+00"<br/>
       0xc, "# ?/?"<br/>
       0xd, "# ??/??"<br/>
       0xe, "m/d/yy"<br/>
       0xf, "d-mmm-yy"<br/>
       0x10, "d-mmm"<br/>
       0x11, "mmm-yy"<br/>
       0x12, "h:mm AM/PM"<br/>
       0x13, "h:mm:ss AM/PM"<br/>
       0x14, "h:mm"<br/>
       0x15, "h:mm:ss"<br/>
       0x16, "m/d/yy h:mm"<br/>
<p/>
       // 0x17 - 0x24 reserved for international and undocumented
       0x25, "#,##0_);(#,##0)"<br/>
       0x26, "#,##0_);[Red](#,##0)"<br/>
       0x27, "#,##0.00_);(#,##0.00)"<br/>
       0x28, "#,##0.00_);[Red](#,##0.00)"<br/>
       0x29, "_(* #,##0_);_(* (#,##0);_(* \"-\"_);_(@_)"<br/>
       0x2a, "_($* #,##0_);_($* (#,##0);_($* \"-\"_);_(@_)"<br/>
       0x2b, "_(* #,##0.00_);_(* (#,##0.00);_(* \"-\"??_);_(@_)"<br/>
       0x2c, "_($* #,##0.00_);_($* (#,##0.00);_($* \"-\"??_);_(@_)"<br/>
       0x2d, "mm:ss"<br/>
       0x2e, "[h]:mm:ss"<br/>
       0x2f, "mm:ss.0"<br/>
       0x30, "##0.0E+0"<br/>
       0x31, "@" - This is text format.<br/>
       0x31  "text" - Alias for "@"<br/>
 <p/></div>
<dl><dt><span class="strong">Author:</span></dt>
  <dd>Yegor Kozlov

 Modified 6/17/09 by Stanislav Shor - positive formats don't need starting '('
 Modified 10/31/13 by Eric Peters - * is a repeating/padding character directive, examples needed a space after the asterix (e.i. Accounting format)</dd></dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_summary">
<!--   -->
</a>
<h3>Field Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation">
<caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Field and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/ss/usermodel/BuiltinFormats.html#FIRST_USER_DEFINED_FORMAT_INDEX">FIRST_USER_DEFINED_FORMAT_INDEX</a></strong></code>
<div class="block">The first user-defined format starts at 164.</div>
</td>
</tr>
</table>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!--   -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../../org/apache/poi/ss/usermodel/BuiltinFormats.html#BuiltinFormats()">BuiltinFormats</a></strong>()</code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!--   -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static java.lang.String[]</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/ss/usermodel/BuiltinFormats.html#getAll()">getAll</a></strong>()</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static java.lang.String</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/ss/usermodel/BuiltinFormats.html#getBuiltinFormat(int)">getBuiltinFormat</a></strong>(int&nbsp;index)</code>
<div class="block">Get the format string that matches the given format index</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static int</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/ss/usermodel/BuiltinFormats.html#getBuiltinFormat(java.lang.String)">getBuiltinFormat</a></strong>(java.lang.String&nbsp;pFmt)</code>
<div class="block">Get the format index that matches the given format string
 <p/>
 Automatically converts "text" to excel's format string to represent text.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static java.util.Map&lt;java.lang.Integer,java.lang.String&gt;</code></td>
<td class="colLast"><code><strong><a href="../../../../../org/apache/poi/ss/usermodel/BuiltinFormats.html#getBuiltinFormats()">getBuiltinFormats</a></strong>()</code>
<div class="block"><strong>Deprecated.</strong>&nbsp;
<div class="block"><i>(May 2009) use <a href="../../../../../org/apache/poi/ss/usermodel/BuiltinFormats.html#getAll()"><code>getAll()</code></a></i></div>
</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!--   -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.Object</h3>
<code>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ============ FIELD DETAIL =========== -->
<ul class="blockList">
<li class="blockList"><a name="field_detail">
<!--   -->
</a>
<h3>Field Detail</h3>
<a name="FIRST_USER_DEFINED_FORMAT_INDEX">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>FIRST_USER_DEFINED_FORMAT_INDEX</h4>
<pre>public static final&nbsp;int FIRST_USER_DEFINED_FORMAT_INDEX</pre>
<div class="block">The first user-defined format starts at 164.</div>
<dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../../constant-values.html#org.apache.poi.ss.usermodel.BuiltinFormats.FIRST_USER_DEFINED_FORMAT_INDEX">Constant Field Values</a></dd></dl>
</li>
</ul>
</li>
</ul>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!--   -->
</a>
<h3>Constructor Detail</h3>
<a name="BuiltinFormats()">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>BuiltinFormats</h4>
<pre>public&nbsp;BuiltinFormats()</pre>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!--   -->
</a>
<h3>Method Detail</h3>
<a name="getBuiltinFormats()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBuiltinFormats</h4>
<pre>public static&nbsp;java.util.Map&lt;java.lang.Integer,java.lang.String&gt;&nbsp;getBuiltinFormats()</pre>
<div class="block"><span class="strong">Deprecated.</span>&nbsp;<i>(May 2009) use <a href="../../../../../org/apache/poi/ss/usermodel/BuiltinFormats.html#getAll()"><code>getAll()</code></a></i></div>
</li>
</ul>
<a name="getAll()">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAll</h4>
<pre>public static&nbsp;java.lang.String[]&nbsp;getAll()</pre>
<dl><dt><span class="strong">Returns:</span></dt><dd>array of built-in data formats</dd></dl>
</li>
</ul>
<a name="getBuiltinFormat(int)">
<!--   -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBuiltinFormat</h4>
<pre>public static&nbsp;java.lang.String&nbsp;getBuiltinFormat(int&nbsp;index)</pre>
<div class="block">Get the format string that matches the given format index</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>index</code> - of a built in format</dd>
<dt><span class="strong">Returns:</span></dt><dd>string represented at index of format or <code>null</code> if there is not a built-in format at that index</dd></dl>
</li>
</ul>
<a name="getBuiltinFormat(java.lang.String)">
<!--   -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getBuiltinFormat</h4>
<pre>public static&nbsp;int&nbsp;getBuiltinFormat(java.lang.String&nbsp;pFmt)</pre>
<div class="block">Get the format index that matches the given format string
 <p/>
 Automatically converts "text" to excel's format string to represent text.
 </p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>pFmt</code> - string matching a built-in format</dd>
<dt><span class="strong">Returns:</span></dt><dd>index of format or -1 if undefined.</dd></dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!--   -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!--   -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/BuiltinFormats.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../../org/apache/poi/ss/usermodel/BorderStyle.html" title="enum in org.apache.poi.ss.usermodel"><span class="strong">PREV CLASS</span></a></li>
<li><a href="../../../../../org/apache/poi/ss/usermodel/Cell.html" title="interface in org.apache.poi.ss.usermodel"><span class="strong">NEXT CLASS</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../../index.html?org/apache/poi/ss/usermodel/BuiltinFormats.html" target="_top">FRAMES</a></li>
<li><a href="BuiltinFormats.html" target="_top">NO FRAMES</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
  allClassesLink = document.getElementById("allclasses_navbar_bottom");
  if(window==top) {
    allClassesLink.style.display = "block";
  }
  else {
    allClassesLink.style.display = "none";
  }
  //-->
</script>
</div>
<div>
<ul class="subNavList">
<li>SUMMARY:&nbsp;</li>
<li>NESTED&nbsp;|&nbsp;</li>
<li><a href="#field_summary">FIELD</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">CONSTR</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">METHOD</a></li>
</ul>
<ul class="subNavList">
<li>DETAIL:&nbsp;</li>
<li><a href="#field_detail">FIELD</a>&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">CONSTR</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">METHOD</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!--   -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>
                <i>Copyright 2014 The Apache Software Foundation or
        its licensors, as applicable.</i>
            </small></p>
</body>
</html>
